#import "dfhgwhruebvhrheyincidentallycomet.h"
#import "dfhgwhruebvhrheychoruspea.h"
#import "dfhgwhruebvhrheyignoreestablish.h"
@implementation dfhgwhruebvhrheychoruspea {
	UIButton *okBtn;
	void(^_click)(void);
	dfhgwhruebvhrheyignoreestablish * serviceFeeView;
	dfhgwhruebvhrheyignoreestablish * technicalView;
	dfhgwhruebvhrheyignoreestablish * managementView;
	dfhgwhruebvhrheyignoreestablish * assessmentView;
}
- (instancetype)initWithFrame:(CGRect)frame {
	if(self = [super initWithFrame:frame]) {
		[self setUI];
	}
	return self;
}
- (void)setUI {
	self.layer.cornerRadius = 20;
	self.layer.masksToBounds = YES;
	self.backgroundColor = [UIColor whiteColor];
	serviceFeeView = [[dfhgwhruebvhrheyignoreestablish alloc] init];
	serviceFeeView.backgroundColor = primary_color.dhgfywegwygeydwlearneddesignate;
	[self addSubview:serviceFeeView];
	technicalView = [[dfhgwhruebvhrheyignoreestablish alloc] init];
	[self addSubview:technicalView];
	managementView = [[dfhgwhruebvhrheyignoreestablish alloc] init];
	[self addSubview:managementView];
	assessmentView = [[dfhgwhruebvhrheyignoreestablish alloc] init];
	[self addSubview:assessmentView];
	okBtn = [UIButton buttonWithType:UIButtonTypeCustom];
	okBtn.titleLabel.font = [UIFont semiBold:15];
	okBtn.layer.cornerRadius = 10;
	okBtn.backgroundColor = primary_color.dhgfywegwygeydwlearneddesignate;
	[okBtn setTitle:@"ok" forState:UIControlStateNormal];
	[okBtn setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
	[okBtn addTarget:self action:@selector(okBtnAction) forControlEvents:UIControlEventTouchUpInside];
	[self addSubview:okBtn];
}
- (void)bindData:(dfhgwhruebvhrheyincidentallycomet *)data andClick:(void(^)(void))click {
	_click = click;
	NSString *serviceFeeString = [NSString stringWithFormat:@"%d", data.service_fee].dhgfywegwygeydwlocalitylearned;
	[serviceFeeView setTitle:@"Service Fee" andDesc:[NSString stringWithFormat:@"PHP %@",serviceFeeString] withColor:[UIColor whiteColor]];
	NSString *technicalString = [NSString stringWithFormat:@"%d", data.tech_price].dhgfywegwygeydwlocalitylearned;
	[technicalView setTitle:@"Technical Service Fees" andDesc:[NSString stringWithFormat:@"PHP %@",technicalString] withColor:nil];
	NSString *managementString = [NSString stringWithFormat:@"%d", data.manage_price].dhgfywegwygeydwlocalitylearned;
	[managementView setTitle:@"Account Management Fees" andDesc:[NSString stringWithFormat:@"PHP %@",managementString] withColor:nil];
	NSString *assessmentString = [NSString stringWithFormat:@"%d", data.credit_price].dhgfywegwygeydwlocalitylearned;
	[assessmentView setTitle:@"Credit Assessment Fees" andDesc:[NSString stringWithFormat:@"PHP %@",assessmentString] withColor:nil];
}
- (void)okBtnAction {
	if(_click) {
		_click();
	}
}
- (void)layoutSubviews {
	[super layoutSubviews];
	[serviceFeeView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.left.top.right.equalTo(self);
		make.height.mas_equalTo(50);
	}];
	[technicalView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.top.equalTo(serviceFeeView.mas_bottom);
		make.left.height.right.mas_equalTo(serviceFeeView);
	}];
	[managementView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.top.equalTo(technicalView.mas_bottom);
		make.left.height.right.mas_equalTo(technicalView);
	}];
	[assessmentView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.top.equalTo(managementView.mas_bottom);
		make.left.height.right.mas_equalTo(managementView);
	}];
	[okBtn mas_makeConstraints:^(MASConstraintMaker *make) {
		make.top.equalTo(assessmentView.mas_bottom).offset(19);
		make.size.mas_equalTo(CGSizeMake(130, 45));
		make.centerX.equalTo(self);
	}];
}
@end
